[][src]Crate atat_derive

Derive crate for ATAT

This crate provides derive macros for automatically deriving atat::AtatCmd, atat::AtatResp, atat::AtatUrc, atat::AtatEnum and atat::AtatLen

Examples

AtatCmd

See AtatCmd for descriptions and documentation on required and allowed attributes

This example is not tested
// Serializing the following struct, results in `AT+USORD=<socket>,<length>\r\n`
#[derive(AtatCmd)]
#[at_cmd("+USORD", SocketData)]
pub struct ReadSocketData {
    #[at_arg(position = 0)]
    pub socket: u8,
    #[at_arg(position = 1)]
    pub length: usize,
}

Derive Macros

AtatCmd

Automatically derive atat::AtatCmd trait

AtatEnum

Automatically derive atat::AtatEnum trait

AtatLen

Automatically derive atat::AtatLen trait

AtatResp

Automatically derive atat::AtatResp trait

AtatUrc

Automatically derive atat::AtatUrc trait